System and method for animating collision-free sequences of motions for objects placed across a surface

ABSTRACT

Embodiments of the invention set forth a technique for animating objects placed across a surface of a graphics object. A CAD application receives a set of motions and initially applies a different motion in the set of motions to each object placed across the surface of the graphics object. The CAD application calculates bounding areas of each object according to the current motion applied thereto, which are subsequently used by the CAD application to identify collisions that are occurring or will occur between the objects. Identified collisions are cured by identifying valid motions in the set of motions that can be applied to a colliding object and then calculating bounding areas for the valid motions to select a valid motion that, when applied to the object, does not cause the object to collide with any other objects.

CROSS-REFERENCE TO RELATED APPLICATIONS

This application is a continuation of issued U.S. patent titled, “SYSTEM AND METHOD FOR ANIMATING COLLISION-FREE SEQUENCES OF MOTIONS FOR OBJECTS PLACED ACROSS A SURFACE,” filed on Jul. 31, 2012 and having U.S. Pat. No. 9,355,500 B2, which claims the priority benefit of U.S. Provisional Application titled, “CROWD SIMULATION WITH OBJECT AVOIDANCE,” filed on Aug. 1, 2011 and having Application No. 61/513,985. The subject matter of these related applications is hereby incorporated herein by reference.

BACKGROUND OF THE INVENTION

Field of the Invention

The invention relates generally to the field of crowd simulation in computer software and, more specifically, to animating collision-free sequences of motions for objects placed across a surface of a graphics object.

Description of the Related Art

Crowd simulation is the process of simulating a crowd having a large number of objects placed within a computer-generated crowd area. Typically, a graphics designer places the objects within the crowd area via manual selection of a different location onto which each object should be placed. The graphics designer is then faced with the task of animating each of the objects so that they behave and interact with one another in a natural manner. According to conventional approaches, the graphics designer selects each object and then applies a particular animation to the object, e.g., a guard standing post at an entrance. However, manual application of animations creates a variety of problems that are exacerbated as the number of objects placed within the crowd area increases.

One problem is that the graphics designer must ensure that the objects, when animated according to the animation applied thereto, do not collide with one another. The graphics designer must also ensure that the animated objects behave in a diversified manner in order to promote a natural feeling to the crowd area, which is especially difficult when working with long animations that include a number of different behaviors. These types of issues require the graphics designer to make a large number of passes through the animation and continuously fine-tune the animations of each object. What results is a tedious and cumbersome process for the graphics designer.

As the foregoing illustrates, what is needed in the art is an improved technique for animating objects within a crowd area in computer-generated crowd simulation.

SUMMARY OF THE INVENTION

One embodiment of the invention sets forth a method for animating, in a computer-generated simulation, a plurality of objects that are placed across a surface of a graphics object. The method includes the steps of receiving a specification of a total amount of time for the computer-generated simulation to execute, applying, to a first object in the plurality of objects, a first motion from a set of motions, wherein the first motion causes the first object to be animated for a first amount of time, applying, to a second object in the plurality of objects, a second motion from the set of motions, wherein the second motion causes the second object to be animated for a second amount of time, establishing, for the first object, a first bounding area that represents a largest area covered by the first object when animated by the first motion, establishing, for the second object, a second bounding area that represents a largest area covered by the second object when animated by the second motion, determining that the first motion terminates prior to the total amount of time for the computer-generated simulation and prior to the second amount of time, identifying a third motion in the set of motions that is a valid motion to be applied to the first object, establishing a third bounding area for the first object based on the third motion, determining that the third bounding area does not intersect with the second bounding area of the second object, and scheduling the third motion to be applied to the first object when the first motion terminates.

One advantage of the disclosed technique that the cumbersome manual selection process of applying different motions to objects in a computer-generated crowd simulation are eliminated, Instead, the disclosed technique provides a method for automatically animating a plurality of objects in a diverse manner while preventing those objects from colliding with one another at any time during the duration of the computer-generated crowd simulation.

BRIEF DESCRIPTION OF THE DRAWINGS

So that the manner in which the above recited features of the invention can be understood in detail, a more particular description of the invention, briefly summarized above, may be had by reference to embodiments, some of which are illustrated in the appended drawings. It is to be noted, however, that the appended drawings illustrate only typical embodiments of this invention and are therefore not to be considered limiting of its scope, for the invention may admit to other equally effective embodiments.

FIG. 1 is a block diagram of a system configured to implement one or more aspects of the invention.

FIGS. 2A-2B illustrate a flow diagram of method steps for assigning collision-free motions to objects that are placed across a surface of a graphics object, according to one embodiment of the present invention.

FIGS. 3A-3C are conceptual diagrams that illustrate the establishment of bounding areas for objects and groups of objects, according to one embodiment of the invention.

DETAILED DESCRIPTION

In the following description, numerous specific details are set forth to provide a more thorough understanding of the invention. However, it will be apparent to one of skill in the art that the invention may be practiced without one or more of these specific details. In other instances, well-known features have not been described in order to avoid obscuring the invention.

FIG. 1 illustrates a conceptual block diagram of a general purpose computer system 100 configured to implement one or more aspects of the invention. As shown, computer system 100 includes processor 102 (e.g., a CPU), memory 104, e.g., random access memory (RAM) and/or read only memory (ROM), and various input/output devices 106, which may include storage devices including, but not limited to, a tape drive, a floppy drive, a hard disk drive or a compact disk drive, a receiver, a transmitter, a speaker, a display, a speech synthesizer, an output port, and a user input device such as a keyboard, a keypad, a mouse, and the like.

As shown in FIG. 1, computer system 100 is configured to execute CAD application 108, which includes a GUI 110 and an animation engine 112. As described in further detail herein, animation engine 112 is configured to automatically assign motions to objects (e.g., individuals) placed across a surface of a two-dimensional or a three-dimensional graphics object. In particular, and as described in further detail herein, animation engine 112 receives a graphics object of any shape or form—e.g., concave, convex, continuous, discontinuous—that includes at least one object placed on the surface of the graphics object. According to various embodiments, animation engine 112 is configured to animate the objects in a manner that promotes a natural diversity of motions and ensures that the animated objects do not collide with one another. In particular, animation engine 112 is configured to assign animations to objects based on whether they are alone or are part of a group. If an object is part of a group, animation engine 112 assigns to the object a talking animation or a listening animation depending on the animations assigned to other objects that are part of the group. Animation engine 112 is also configured to avoid assigning the same animation to two or more objects that are proximate to one another on the surface within a particular threshold. Animation engine 112 is further configured to avoid assigning animations to objects that would cause the object to collide with another object. Finally, animation engine 112 is configured to avoid assigning highly-noticeable animations to objects when there are less-noticeable animations that can be assigned to the objects.

FIGS. 2A-2B illustrate a flow diagram of method steps for assigning collision-free motions to objects that are placed across a surface of a graphics object, according to one embodiment of the present invention. Although the method steps are described in conjunction with FIGS. 1 and 3A-3C, persons skilled in the art will understand that any system configured to perform the method steps, in any order, falls within the scope of the present invention.

As shown in FIG. 2A, method 200 begins at step 202, where animation engine 112 receives a set of objects that are placed onto a surface of a graphics object. At step 204, animation engine 112 receives a set of motions, where each motion in the set of motions defines a behavior to be acted out by an object for a period of time when applied thereto.

In one embodiment, each motion is implemented as a data object with various properties that are considered by animation engine 112 prior to assigning the motion to an object. One example of a property is a unique identifier for the motion. Another example of a property is a tag that indicates whether the motion should be applied to an object that has been set as a standalone object, a talker in a group, or a listener in a group. For example, FIG. 3A depicts an illustration 302 of a standalone object to which a motion has not yet been applied. Yet another example of a property is a tag that indicates whether the motion is a highly-noticeable. Yet another example of a property is a duration value that indicates the total duration of the animation.

At step 206, animation engine 112 receives a specification of a duration to execute a simulation of animated objects. At step 208, animation engine 112 randomly applies, to each object in the set of objects, a different motion from the set of motions, and, further, calculates a bounding area around the object, where the calculated bounding area represents the largest area that is covered by the object when animated according to the motion assigned thereto. The calculated bounding area is then associated with the object such that it can be compared to the bounding areas of other objects in order to prevent assigning motions to objects that would cause the objects to collide with one another.

FIGS. 3A-3C illustrate examples of bounding areas that are calculated for both standalone objects and objects that are part of a group. For example, FIG. 3A includes example illustrations 302-308 of an object to which a cell-phone conversation motion is applied. The bounding area around the object is expanded as the object carries out the motion, thereby resulting in a bounding area in illustration 308 that represents the widest range of motion of the object throughout the cell-phone conversation motion. As described in further detail herein, the bounding area is subsequently compared to other bounding areas to avoid current and/or future collisions.

Similarly, FIGS. 3B-3C illustrate examples of bounding areas that are calculated for both a standalone object that is near a group and objects that are part of the group. In particular, illustration 310 captures the standalone object and the group of objects before any animation is applied thereto, and illustration 312 captures the standalone object and the group of objects after various animations have been applied thereto. Illustrations 314 and 316 capture bounding areas whose sizes have been increased to reflect the widest range of motion of each object according to the animation applied thereto, which, as described above, are subsequently used to determine whether the animations cause any collisions to occur between the standalone object and/or the objects in the group of objects.

At step 210, animation engine 112 determines whether a target object exists whose current motion ends the soonest and ends before the specified duration. For example, if the specified duration is one minute, and there are two objects whose current applied motions are ten seconds total in length, where the motion of the first object has been executing for 5 seconds, and where the motion of the second object has been executing for 9 seconds, then the second object is chosen at step 210.

If, at step 210, animation engine 112 determines that no target object exists whose current motion ends the soonest and ends before the specified duration, then the simulation is complete, and method 200 ends. Otherwise, method 200 proceeds to step 212, where animation engine 112 executes subroutine A 275, which is illustrated in FIG. 2B.

At step 214, animation engine 112 creates a subset of valid motions that can be applied to the target object by selecting motions that are applicable to a type of the target object (e.g., a standalone object, a talker in a group, or a listener in a group) as well as motions that have not been blocked from being applied to the target object. At step 216, animation engine 112 determines whether at least one motion is included in the subset of valid motions. If, at step 216, animation engine 112 determines that the subset of valid motions is empty, then method 200 proceeds to step 218 and returns null, since there is not a valid motion that can be applied to the target object.

Otherwise, at step 220, animation engine 112 determines whether the target object is part of a group of objects. If so, method 200 proceeds to step 222, where animation engine 112 determines whether the target object is a listener and no listener motions in the subset can be applied to the target object. If, at step 222, animation engine 112 determines that the target object is a listener and no listener motions in the subset can be applied to the target object, then at step 224 animation engine 112 sets the type of the target object to a talker, and method 200 proceeds back to step 214 described above. In this way, the target object is converted to a talker, and animation engine 112 subsequently attempts to identify and assign valid talking motions to the target object according to steps 214-216 described above.

At step 226, animation engine 112 determines whether the target object is a talker and no talker motions can be applied to the target object. If so, method 200 proceeds to step 228, where animation engine 112 returns null since there is not a valid motion that can be applied to the target object. Otherwise, method 200 proceeds to step 230, where animation engine 112 sets the type of the target object to a listener. In this way, the target object is converted to a listener, and animation engine 112 subsequently attempts to identify and assign valid listening motions to the target object according to steps 214-216 described above.

Referring back now to step 220, if animation engine 112 determines that the target object is not part of a group of objects, i.e., the target object a standalone object, then method 200 proceeds to step 232, where animation engine 112 determines whether the subset of valid motions includes a motion that is not being performed by any object in the set of objects. If, at step 232, animation engine 112 determines that the subset of valid motions includes a motion that is not being performed by any object in the set of objects, then at step 234, animation engine 112 returns the motion. Otherwise, method 200 proceeds to step 236, where animation engine 112 parses the subset of valid motions for 1) a motion that is not a noticeable motion and is the same motion as the motion that is currently applied to the target object, 2) a motion that is not a noticeable motion, or 3) a motion that is applied an object that is farthest away from the target object.

At step 238, animation engine 112 determines whether a motion according to 1), 2) or 3) in step 236 is found. If, at step 238, animation engine 112 identifies a motion in the subset of motions that meets the criteria of 1), 2) or 3) in step 236, then at step 242 animation engine 112 returns the motion. Otherwise, at step 240 animation engine 112 returns null, and method 200 returns to step 244 in FIG. 2A.

At step 244, animation engine 112 determines whether a potential motion is found for the target object via subroutine A. If, at step 244, animation engine 112 determines that a potential motion was not found for the target object via subroutine A, i.e., a null value was returned, then method 200 proceeds to step 246, where animation engine 112 removes the object from the surface of the graphics object. Method 200 then returns to step 210, where animation engine 112 finds the next target object, if any, to which a new motion should be applied.

Referring back now to step 244, if animation engine 112 determines that a potential motion was found for the target object via subroutine A 275, then method 200 proceeds to step 248, where animation engine 112 determines whether the potential motion intersects with motions of objects that surround the target object. If, at step 248, animation engine 112 determines that the potential motion intersects with the motion of at least one other object, then method 200 proceeds to step 252, where animation engine 112 blocks the potential motion from being applied to the target object. Animation engine 112 then re-executes subroutine A 275 in order to identify the next potential motion, if any, to apply to the target object.

Referring back to step 258, if animation engine 112 determines that the potential motion does not intersect with the motion of other objects, then method 200 proceeds to step 250, where animation engine 112 schedules the potential motion to be applied to the target object when the current motion of the target object ends. Method 200 then returns back to step 210, and method steps 210-252 continue to execute so long as the duration of the simulation has not been reached and there exists at least one object whose animation ends before the simulation has completed.

In sum, embodiments of the invention set forth a technique that includes animating objects that are placed across a surface of a graphics object. A CAD application receives a set of motions and initially applies a different motion in the set of motions to each object placed across the surface of the graphics object. The CAD application calculates bounding areas of each object according to the current motion applied thereto, which are used by the CAD application to identify collisions that are occurring or will occur between the objects. A colliding object is cured by identifying valid motions in the set of motions that can be applied to the object and then calculating bounding areas for the valid motions until the discovery of a valid motion that, when applied to the object; does not cause the object to collide with any other objects that are placed across the surface of the graphics object.

One advantage of the disclosed technique is that objects placed across a surface of a graphics object are animated in a manner that promotes a natural diversity and flow of motions of the objects. The natural diversity is attained by avoiding the assignment of the same or similar motions to two objects that are proximate to one another beyond a particular threshold, by avoiding assignment of animations to objects that would cause the object to collide with another object, and by avoiding the assignment of highly-noticeable animations to objects when there are less-noticeable animations that can be assigned to the objects.

One embodiment of the invention may be implemented as a program product for use with a computer system. The program(s) of the program product define functions of the embodiments (including the methods described herein) and can be contained on a variety of computer-readable storage media. Illustrative computer-readable storage media include, but are not limited to: (i) non-writable storage media (e.g., read-only memory devices within a computer such as compact disc read only memory (CD-ROM) disks readable by a CD-ROM drive, flash memory, read only memory (ROM) chips or any type of solid-state non-volatile semiconductor memory) on which information is permanently stored; and (ii) writable storage media (e.g., floppy disks within a diskette drive or hard-disk drive or any type of solid-state random-access semiconductor memory) on which alterable information is stored.

The invention has been described above with reference to specific embodiments. Persons of ordinary skill in the art, however, will understand that various modifications and changes may be made thereto without departing from the broader spirit and scope of the invention as set forth in the appended claims. The foregoing description and drawings are, accordingly, to be regarded in an illustrative rather than a restrictive sense.

Therefore, the scope of embodiments of the present invention is set forth in the claims that follow. 

What is claimed is:
 1. A computer-implemented method for generating aR computerized animation, the method comprising: applying, via a processor, a first motion included in a set of motions to a first object in the computerized animation; establishing, for a second object in the computerized animation, a first bounding area that represents an area covered by the second object when digitally animated by a second motion included in the set of motions; establishing, for the first object, a second bounding area that represents an area covered by the first object when digitally animated by a third motion included in the set of motions; determining that the second bounding area does not intersect the first bounding area; and scheduling the third motion to be applied to the first object when the first motion terminates.
 2. The method of claim 1, further comprising blocking a fourth motion included in the set of motions from being applied to the first object when applying the fourth motion to the first object would cause the first object to collide with another object.
 3. The method of claim 1, wherein the third motion is considered to be a valid motion when the third motion is not blocked from being assigned to the first object and meets a type requirement of the first object.
 4. The method of claim 1, wherein the third motion is chosen over a fifth motion when the third motion is being applied to an object that is located farthest from the first object, and the third motion is not a noticeable motion.
 5. The method of claim 1, further comprising: determining that the second object is designated as a talker type and that no valid motions in the set of motions can be applied to the talker type; reclassifying the second object as a listener type; identifying at least one valid motion in the set of motions that can be applied to the listener type; and applying the at least one valid motion to the second object.
 6. The method of claim 1, further comprising: determining that the second object is designated as a listener type and that no valid motions in the set of motions can be applied to the listener type; reclassifying the second object as a talker type; identifying at least one valid motion in the set of motions that can be applied to the talker type; and applying the at least one valid motion to the second object.
 7. The method of claim 1, wherein applying the first motion to the first object comprises selecting at random the first motion from the set of motions, and applying the first motion to the first object.
 8. The method of claim 1, further comprising applying the second motion to the second object.
 9. The method of claim 8, further comprising determining that the first motion terminates prior to a total duration for the computerized animation and prior to when the second motion terminates.
 10. The method of claim 1, further comprising blocking a fourth motion included in the set of motions from being applied to the first object when the fourth motion is being applied to another object that is located within a threshold distance of the first object.
 11. A non-transitory computer-readable medium including instructions that, when executed by a processor, cause the processor to perform the steps of: applying, via the processor, a first motion included in a set of motions to a first object in the computerized animation; establishing, for a second object in the computerized animation, a first bounding area that represents an area covered by the second object when digitally animated by a second motion included in the set of motions; establishing, for the first object, a second bounding area that represents an area covered by the first object when digitally animated by a third motion included in the set of motions; determining that the second bounding area does not intersect the first bounding area; and scheduling the third motion to be applied to the first object when the first motion terminates.
 12. The non-transitory computer-readable medium of claim 11, further comprising blocking a fourth motion included in the set of motions from being applied to the first object when applying the fourth motion to the first object would cause the first object to collide with another object.
 13. The non-transitory computer-readable medium of claim 11, wherein the third motion is considered to be a valid motion when the third motion is not blocked from being assigned to the first object and meets a type requirement of the first object.
 14. The non-transitory computer-readable medium of claim 11, wherein the third motion is chosen over a fifth motion when the third motion is being applied to an object that is located farthest from the first object, and the third motion is not a noticeable motion.
 15. The non-transitory computer-readable medium of claim 11, further comprising: determining that the second object is designated as a talker type and that no valid motions in the set of motions can be applied to the talker type; reclassifying the second object as a listener type; identifying at least one valid motion in the set of motions that can be applied to the listener type; and applying the at least one valid motion to the second object.
 16. The non-transitory computer-readable medium of claim 11, further comprising: determining that the second object is designated as a listener type and that no valid motions in the set of motions can be applied to the listener type; reclassifying the second object as a talker type; identifying at least one valid motion in the set of motions that can be applied to the talker type; and applying the at least one valid motion to the second object.
 17. The non-transitory computer-readable medium of claim 11, wherein applying the first motion to the first object comprises selecting at random the first motion from the set of motions, and applying the first motion to the first object.
 18. The non-transitory computer-readable medium of claim 11, further comprising applying the second motion to the second object.
 19. The non-transitory computer-readable medium of claim 18, further comprising determining that the first motion terminates prior to a total duration for the computerized animation and prior to when the second motion terminates.
 20. The non-transitory computer-readable medium of claim 11, further comprising blocking a fourth motion included in the set of motions from being applied to the first object when the fourth motion is being applied to another object that is located within a threshold distance of the first object.
 21. A computer system, comprising: a memory including an application program; and a processor that is coupled to the memory and, when executing the application program, is configured to: apply, via the processor, a first motion included in a set of motions to a first object in the computerized animation; establish, for a second object in the computerized animation, a first bounding area that represents an area covered by the second object when digitally animated by a second motion included in the set of motions; establish, for the first object, a second bounding area that represents an area covered by the first object when digitally animated by a third motion included in the set of motions; determine that the second bounding area does not intersect the first bounding area; and schedule the third motion to be applied to the first object when the first motion terminates. 